package cn.xscrum.demo.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import cn.xscrum.demo.mapper.FlowPassengerRateMapper;
import cn.xscrum.demo.domain.FlowPassengerRate;
import cn.xscrum.demo.service.IFlowPassengerRateService;
import cn.xscrum.common.core.text.Convert;

/**
 * 客流量Service业务层处理
 * 
 * @author cyb
 * @date 2020-11-25
 */
@Service
public class FlowPassengerRateServiceImpl implements IFlowPassengerRateService 
{
    @Autowired
    private FlowPassengerRateMapper flowPassengerRateMapper;

    /**
	 * 查询客流量
     * 
     * @param id 客流量ID
     * @return 客流量
     */
    @Override
    public FlowPassengerRate selectFlowPassengerRateById(Long id)
    {
        return flowPassengerRateMapper.selectFlowPassengerRateById(id);
    }

    /**
	 * 查询客流量列表
     * 
     * @param flowPassengerRate 客流量
     * @return 客流量
     */
    @Override
    public List<FlowPassengerRate> selectFlowPassengerRateList(FlowPassengerRate flowPassengerRate)
    {
        return flowPassengerRateMapper.selectFlowPassengerRateList(flowPassengerRate);
    }

    /**
	 * 新增客流量
     * 
     * @param flowPassengerRate 客流量
     * @return 结果
     */
    @Override
    public int insertFlowPassengerRate(FlowPassengerRate flowPassengerRate)
    {
        return flowPassengerRateMapper.insertFlowPassengerRate(flowPassengerRate);
    }

    /**
	 * 修改客流量
     * 
     * @param flowPassengerRate 客流量
     * @return 结果
     */
    @Override
    public int updateFlowPassengerRate(FlowPassengerRate flowPassengerRate)
    {
        return flowPassengerRateMapper.updateFlowPassengerRate(flowPassengerRate);
    }

    /**
	 * 删除客流量对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteFlowPassengerRateByIds(String ids)
    {
        return flowPassengerRateMapper.deleteFlowPassengerRateByIds(Convert.toStrArray(ids));
    }

    /**
	 * 删除客流量信息
     * 
     * @param id 客流量ID
     * @return 结果
     */
    @Override
    public int deleteFlowPassengerRateById(Long id)
    {
        return flowPassengerRateMapper.deleteFlowPassengerRateById(id);
    }
}
